class shape:
    def __init__(self):
        pass

    def getArea(self):
        pass

    def getP(self):
        pass

class circle(shape):
    pi = 3.14
    def __init__(self, r):
        self._r = r

    def getP(self):
        return 2 * self.pi * self._r

    def getArea(self):
        return self.pi * self._r * self._r

class rect(shape):
    def __init__(self, a, b):
        super().__init__()
        self._a = a
        self._b = b

    def getArea(self):
        return self._a * self._b

    def getP(self):
        return (self._a + self._b) * 2

r = float(input('请输入半径'))
c = circle(r)
a, b = map(float, input('请输入长和宽').split())
rec = rect(a, b)
print('圆的面积为:', c.getArea(), '周长为:', c.getP())
print('矩形的面积为:', rec.getArea(), '矩形的周长为:', c.getP())